{assign $pathMiniature = PHOTO_ANNONCE_PATH}
{assign $pathNormal = PHOTO_ANNONCE_PATH}
{assign $path_annonce_in_datas = PHOTO_ANNONCE_PATH_IN_DATAS }
{assign $path = PHOTO_ANNONCE_PATH}
<input type="hidden" id='path_min' value="{$path}" />
<input type="hidden" id="delImage" value="{$j_basepath}design/front/images/DeleteRed.png" />
<input type="hidden" id="noImage" value="{$j_basepath}design/front/images/no_image.jpg" />
{literal}
	<style>
    	#essai_fiche .chapitre p, td{font-size:12px;}
    </style>
{/literal}
<div id="global" class="search">
  {$oZoneHeader}
  <div id="main">
    <div class="file_ariane">
        {$oZoneBreadCrumb}
    </div>
    
    <!-- begin leftContent2-->
    <div id="leftContent2" style="font-size:12px;">
        
      <div id="essai_fiche">
        <h2>Gérer votre annonce</h2>
        <div class="wrap">
          <div class="block coordonnees">
           <ul class="menu2">
	<li><a class="aCc" href="{jurl 'annonce~FoAnnonceGestion:gererAnnonce',array('idOccasion'=>$idOccasion)}">Accueil</a></li>
    <li><a class="mod" href="{jurl 'annonce~FoAnnonceGestion:edit',array('idOccasion'=>$idOccasion)}">Modifier</a></li>
    <li><a class="fOpt" href="{jurl 'annonce~FoAnnonceGestion:formuleOptions',array('idOccasion'=>$idOccasion)}">Formule/Option</a></li>
    <li><a class="pht active">Photos</a></li>
    <li><a class="vIsu" href="{jurl 'recherche~FoFiche:index',array('id'=>$idOccasion )}" target="_blank">Visualiser</a></li>
    <li><a class="mod2" href="{jurl 'annonce~FoAnnonceGestion:relancer',array('idOccasion'=>$idOccasion)}">Relancer</a></li>
    <li class="last"><a class="sUp" href="{jurl 'annonce~FoAnnonceGestion:supprimer',array('idOccasion'=>$idOccasion)}">Supprimer</a></li>
</ul><br />
            <strong class="titre">Vos photos</strong>
            <form action="{jurl 'annonce~FoAnnonceGestion:savePhotos',array('idOccasion'=>$idOccasion)}" method="post" >
              {if isset($vendeur->IdVendeur)}
                   <input type="hidden" name="vendeur_id" value="{$vendeur->IdVendeur}" />
              {/if}
              
              <div class="photos">
                <div class="wrap">
                    <div class="p1" style="float:left!important;width:412px!important;margin-left:15px!important;">
                        <p><strong>Photo principale gratuite </strong>(vue extérieure du vehicule uniquement)</p>
                        <div class="upload_image" style="width:380px!important;">
                            <img src="{if ($photo_princ != '')}{if (!isset($fimage))}{$pathMiniature}{/if}{$photo_princ}{else}{$j_basepath}design/front/images/no_image.jpg{/if}" id="thumb" title="photo principale" alt="no image"/>
                            <!--chemin du fichier-->
                            <input type="text" value="{if ($photo_princ != '')}{$photo_princ}{/if}" id="fic_princ" name="fic_princ"  class="nom_fic" readonly="true" style="margin-top:22px; margin-left:5px;width:140px;"/>
                            <!-- Upload Button-->
                            <div id="upload" class='btn_upload' style='margin-right:8px!important;'>Parcourir</div>
                            <span id="status_fic" >
                                <img src="{$j_basepath}design/front/images/loading.gif" class="loading"  alt="no image"/>
                                <p></p>
                            </span> 
                        </div>
                        <p><strong>Photos supplementaires</strong> jusqu'a 10 photos</p>

                        <div class="upload_image" style="width:387px!important;">
                            <img src="{$j_basepath}design/front/images/no_image.jpg" id="thumb_supp" alt="no image"/>
                            <!--chemin du fichier-->
                            <input type="text" id="fic_supp" class="nom_fic" readonly="true" style="margin-top:22px; margin-left:5px;width:140px;"/>
                            <!-- Upload Button-->
                            <div id="upload_supp" class='btn_upload' style='margin-right:8px!important;'>Parcourir</div>
                            <span id="status_supp" >
                                <img src="{$j_basepath}design/front/images/loading.gif" class="loading"  alt="no image"/>
                            <p></p>
                            </span> 
                        </div>

                    </div>

                    <!--begin gallery-->
                    
                    <div style="width:220px!important; height:233px; display:block; overflow:hidden; margin:0 auto;">
                    <img id='ap_img' style="width:233px;"  src="{if ($photo_princ != '')}{if (!isset($fimage))}{$pathMiniature}{/if}{$photo_princ}{else}{$j_basepath}design/front/images/no_image.jpg{/if}"  title="Cliquer pour agrandir" style="margin-top:40px!important;"/>
                    <a class="showPP" style="cursor: pointer;position:absolute;margin-left:190px;margin-top:-160px;" href="{if ($photo_princ != '')}{if (!isset($fimage))}{$pathMiniature}{/if}{/if}{$photo_princ}" rel="prettyPhoto[pp_gal]"><img  alt="" src="{$j_basepath}design/front/images/zoom.png" title="Zoom" /></a>
                    <div id="forPopUp"  style="display: none;"> 
                        {if isset($photoSrc)}
                            {foreach $photoSrc as $key=>$item}
                                {if (($key !=0) || (isset($fimage))) && $item->photo_name}
                                    <a href="{$pathMiniature}{$item->photo_name}" rel="prettyPhoto[pp_gal]" title="">
                                    <img src="{$pathMiniature}{$item->photo_name}" width="60" height="60" alt="" /> </a>
                                {/if}

                            {/foreach}
                        {/if}
                     </div>
                    </div>
                    <div class="infiniteCarousel" id="wrapper_carousel" style="margin-top:20px!important;margin-left:15px!important;">
                        <div class="wrapper">
                            <ul>
                                
                                {if ($photo_princ != '')}
                                    <li style="width:60px!important; height:61px!important;">
                                            <img src="{if (!isset($fimage))}{$pathMiniature}{/if}{$photo_princ}" class="photo_princ"  title="{$photo_princ}" style="width:64px!important;" height="64" />
                                            <img src="{$j_basepath}design/front/images/DeleteRed.png" class="deleteImage" title="Supprimer cette image" />
                                    </li>
                                {/if}
                                {if isset($photoSrc)}
                                    {foreach $photoSrc as $key=>$item}
                                        {if (($key !=0) || (isset($fimage))) && $item->photo_name}
                                            <li>
                                                <img src="{$pathMiniature}{$item->photo_name}" title="{$pathMiniature}{$item->photo_name}" style="width:64px!important;" height="64" />
                                                <img src="{$j_basepath}design/front/images/DeleteRed.png" class="deleteImage" title="Supprimer cette image" />
                                            </li>
                                        {/if}
                                        
                                    {/foreach}
                                {/if}
                            </ul>        
                        </div>
                    </div>
                    {literal}
                        <script type='text/javascript'>
                            $('.infiniteCarousel').infiniteCarousel();
                        </script>
                    {/literal}
                    <!--end gallery-->
                </div>
            </div>
            <!-- fin photos -->
            <div class="clear">&nbsp;</div>
            <input type="hidden" name="photo-annonce" value="{if isset($photoSrc)}{foreach $photoSrc as $key=>$item}{if (($key !=0) || (isset($fimage)))}{if ($key >0)},{/if}{$item->photo_name}{/if}{/foreach}{/if}" id="photo-annonce" />
               <div style="float:right;margin-right:80px;margin-bottom:50px;">
                <input type="submit" title="Terminer" value="Terminer">
               </div>
              </form>
          </div>
          <div class="more_link relative"></div>
        </div>
        <div class="deco">&nbsp;</div>
      </div>
      
      
    </div>
    <!-- end leftContent2-->
    <div id="rightContent">
      {$oZoneRightContent}
    </div>
    <div class="clear">&nbsp;</div>
  </div>
  <div id="SideBar"><a href="#global"><img alt="" src="{$j_basepath}design/front/images/top.png" title="" /></a></div>
  </div>
{$oZoneFooter}
{literal}
<style type="text/css">
    #list-img {list-style:none;}
    .FImage {float:left;display:inline;}
    .imglist {border:solid 1px silver; padding:5px;}
</style>
{/literal}
{$oZonePubHidden}